<%@ page language="java" contentType="text/html; charset=utf-8"
    pageEncoding="utf-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>MyJsp!</title>
</head>
<%
	String id="";
    //从cookie中选中keep cookie
    Cookie cookies[] =request.getCookies();
    if(cookies!=null){
    	for(Cookie cookie:cookies){
    		if(cookie.getName().equals("id")){
    			id=cookie.getValue();
    		}
    	}
    }
    System.out.println("第二次的登陆的id="+id);
    request.setAttribute("id", id);
%>
<body background="images/1.jpg">
<form action="login.do" method="post">
	<table height="175px" width="335px" border="0" background="images/login.png" align="center" style="margin-top: 180px;" >
	<tr height="70px"><td align="right" valign="bottom"><font color="red" face="黑体" size="4">用户ID:</font></td><td valign="bottom"><input type="text" name="id" value="${id}"/></td></tr>
	<tr><td align="right" ><font color="red" face="黑体" size="4">密码:</font></td><td><input type="password" name="password"/></td></tr>
	<tr><td></td><td valign="top"><input style="font-size: 15px" type="submit" value="Login"><input type="checkbox" value="keep" name="iskeepinfo"/>保存用户名</td></tr>
	

 </table>
</form>
</body>
</html>